<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>

<div class="t_bar">近两年科技项目情况 </div>
	<table class="t_css" width="100%" id="org_two_kjxm" border="0" cellpadding="0"
	    cellspacing="1">
		<col style="width: 25%"/>
		<col style="width: 15%"/>
		<col style="width: 15%"/>
		<col style="width: 15%"/>
		<col style="width: 15%"/>
		<col style="width: 15%"/>
		
		<tr align="center">
			<td>类型</td>
			<td>合计</td>
			<td>国家级</td>
			<td>省部级</td>
			<td>市级</td>
			<td>县级</td>
		</tr>
		<tr align="center">
			<td align="right">承担财政科技计划项目数（项）：</td>
			<td>
				<input name="proposal/project_total" id="project_total" label="承担财政科技计划项目数-->合计" type="text" onfocus="InitInput.setNumber(this,9,0,0);" 
 				class="input_css required  gray" disabled="disabled" style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/project_total" />"/>
 			</td>
			<td>
				<input name="proposal/project_country" id="project_country" onchange="count_tt()" label="承担财政科技计划项目数-->国家级" type="text" onfocus="InitInput.setNumber(this,9,0,0);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/project_country" />"/>
 			</td>
			<td>
				<input name="proposal/project_provence" id="project_provence" onchange="count_tt()" label="承担财政科技计划项目数-->省部级" type="text" onfocus="InitInput.setNumber(this,9,0,0);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/project_provence" />"/>
 			</td>
			<td>
				<input name="proposal/project_city" id="project_city" label="承担财政科技计划项目数-->市级" onchange="count_tt()" type="text" onfocus="InitInput.setNumber(this,9,0,0);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/project_city" />"/>
 			</td>
			<td>
				<input name="proposal/project_town" id="project_town" label="承担财政科技计划项目数-->县级" onchange="count_tt()" type="text" onfocus="InitInput.setNumber(this,9,0,0);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/project_town" />"/>
 			</td>
		</tr>
		<tr align="center">
			<td align="right">承担财政科技计划金额（万元）：</td>
			<td>
				<input name="proposal/gon_pfund_total" id="gon_pfund_total" label="承担财政科技计划金额-->合计" type="text" onfocus="InitInput.setNumber(this,9,2,2);" 
 				class="input_css required gray" disabled="disabled"  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/gon_pfund_total" />"/>
 			</td>
			<td>
				<input name="proposal/gon_pfund_country" id="gon_pfund_country" label="承担财政科技计划金额-->国家级" onchange="count_tt()" type="text" onfocus="InitInput.setNumber(this,9,2,2);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/gon_pfund_country" />"/>
 			</td>
			<td>
				<input name="proposal/gon_pfund_provence" id="gon_pfund_provence" label="承担财政科技计划金额-->省部级" onchange="count_tt()" type="text" onfocus="InitInput.setNumber(this,9,2,2);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/gon_pfund_provence" />"/>
 			</td>
			<td>
				<input name="proposal/gon_pfund_city" id="gon_pfund_city" label="承担财政科技计划金额-->市级" onchange="count_tt()" type="text" onfocus="InitInput.setNumber(this,9,2,2);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/gon_pfund_city" />"/>
 			</td>
			<td>
				<input name="proposal/gon_pfund_town" id="gon_pfund_town" label="承担财政科技计划金额-->县级" onchange="count_tt()" type="text" onfocus="InitInput.setNumber(this,9,2,2);" 
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/gon_pfund_town" />"/>
 			</td>
		</tr>
		
		<tr align="center">
			<td align="right">承担企业科技项目数（项）：</td>
			<td>
				<input name="proposal/cd_prj_num" id="cd_prj_num" label="承担企业科技项目数" type="text" onfocus="InitInput.setNumber(this,9,0,0);"
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/cd_prj_num" />"/>
			</td>
			<td align="right" colspan="2">承担企业科技项目金额（万元）：</td>
			<td style="border-right: none;">
				<input name="proposal/cd_prj_fund" id="cd_prj_fund" label="承担企业科技项目金额" type="text" onfocus="InitInput.setNumber(this,9,2,2);"
 				class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/cd_prj_fund" />"/>
			</td>
			<td style="border-left: none;"></td>
		</tr>
		<tr align="center">
			<td align="right">自主立项研发项目数（项）：</td>
			<td>
				<input name="proposal/self_prj_num" id="self_prj_num" label="自主立项研发项目数" type="text" onfocus="InitInput.setNumber(this,9,0,0);"
					   class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/self_prj_num" />"/>
			</td>
			<td align="right" colspan="2">自主立项研发项目金额（万元）：</td>
			<td style="border-right: none;">
				<input name="proposal/self_prj_fund" id="self_prj_fund" label="自主立项研发项目金额" type="text" onfocus="InitInput.setNumber(this,9,2,2);"
					   class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/self_prj_fund" />"/>
			</td>
			<td style="border-left: none;"></td>
		</tr>
		<tr align="center">
			<td align="right">合作研发项目数（项）：</td>
			<td>
				<input name="proposal/hz_prj_num" id="hz_prj_num" label="合作研发项目数" type="text" onfocus="InitInput.setNumber(this,9,0,0);"
					   class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/hz_prj_num" />"/>
			</td>
			<td align="right" colspan="2">合作研发项目自身投入经费数（万元）：</td>
			<td style="border-right: none;">
				<input name="proposal/hz_prj_fund" id="hz_prj_fund" label="合作研发项目自身投入经费数" type="text" onfocus="InitInput.setNumber(this,9,2,2);"
					   class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/hz_prj_fund" />"/>
			</td>
			<td style="border-left: none;"></td>
		</tr>
		<tr align="center">
			<td align="right">委托研发项目数（项）：</td>
			<td>
				<input name="proposal/wt_prj_num" id="wt_prj_num" label="委托研发项目数" type="text" onfocus="InitInput.setNumber(this,9,0,0);"
					   class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/wt_prj_num" />"/>
			</td>
			<td align="right" colspan="2">委托研发项目金额（万元）：</td>
			<td style="border-right: none;">
				<input name="proposal/wt_prj_fund" id="wt_prj_fund" label="委托研发项目金额" type="text" onfocus="InitInput.setNumber(this,9,2,2);"
					   class="input_css required "  style="text-align: right;width: 80%;"  value="<x:out select="$xmlData/data/proposal/wt_prj_fund" />"/>
			</td>
			<td style="border-left: none;"></td>
		</tr>
	</table>
<script type="text/javascript">
function formatVal(count) {
	if (!$.isNumeric(count))
	count = "0";
	count = ((parseFloat(count) * 10000) / 10000).toFixed(4);
	count = formatNumberAuto(count.toString(), 9, 2, 2);// 格式化金额
	return count;
}
function  count_tt(){
	var total1=0;
	var total2=0;
	$("#org_two_kjxm tr:eq(1) td:gt(1)").each(function(){
		var value=parseFloat($(this).find("input").val());
		if(!!!value){
			value=0;
		}
		total1=total1+value;
	});
	$("#org_two_kjxm tr:eq(2) td:gt(1)").each(function(){
		var value=parseFloat($(this).find("input").val());
		if(!!!value){
			value=0;
		}
		total2=total2+value;
	});
	$("#project_total").val(total1);
	$("#gon_pfund_total").val(formatVal(total2));
}
</script>		
